{#
SPDX-FileCopyrightText:  2020-2021 zPlus <zplus@peers.community>
SPDX-License-Identifier: GPL-2.0-only
#}

{% if actor['type'] == 'Person' %}

    <div class="mb-5">
        <div>
            <span class="font-weight-bold">{{ actor['name'] }}</span>
            (<a href="{{ actor['id'] }}" target="_blank">{{actor['id']}}</a>)
        </div>
        <div>
            <span class="font-italic mr-2">{{ actor['type'] }}</span>

        {#
            <a href="{{ url_for('forgefed_ns.federation_follow', actor_uri=actor['id']) }}" class="mr-2">
                Follow
            </a>
        #}
        </div>
    </div>

{% elif actor['type'] == 'Project' %}

    <div class="mb-5">
        <div>
            <span class="font-weight-bold">{{ actor['name'] }}</span>
            (<a href="{{ actor['id'] }}" target="_blank">{{actor['id']}}</a>)
        </div>
        <div>
            <span class="font-italic mr-2">{{ actor['type'] }}:</span>

            <a href="{{ url_for('forgefed_ns.federation_submit_ticket', actor_uri=actor['id']) }}" class="mr-2">
                Submit ticket
            </a>
            <a href="" class="mr-2">
                Send patch
            </a>
        </div>
    </div>

{% elif actor['type'] == 'Repository' %}

    <div class="mb-5">
        <div>
            <span class="font-weight-bold">{{ actor['name'] }}</span>
            (<a href="{{ actor['id'] }}" target="_blank">{{actor['id']}}</a>)
        </div>
        <div>
            <span class="font-italic mr-2">{{ actor['type'] }}</span>

            <a href="{{ url_for('forgefed_ns.federation_fork', repository_uri=actor['id']) }}" class="mr-2">
                Fork
            </a>
        </div>
    </div>

{% elif actor['type'] == 'TicketTracker' %}

    <div class="mb-5">
        <div>
            <span class="font-weight-bold">{{ actor['name'] }}</span>
            (<a href="{{ actor['id'] }}" target="_blank">{{actor['id']}}</a>)
        </div>
        <div>
            <span class="font-italic mr-2">{{ actor['type'] }}</span>

            <a href="{{ url_for('forgefed_ns.federation_submit_ticket', actor_uri=actor['id']) }}" class="mr-2">
                Submit ticket
            </a>
        </div>
    </div>

{% endif %}
